package com.example.happiness.controller.admin;

import com.example.happiness.pojo.adminvo.AdminFeedbackVO;
import com.example.happiness.result.Result;
import com.example.happiness.service.admin.AdminFeedbackService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Api(tags = "管理反馈相关接口")
@Slf4j
@RestController
@RequestMapping("/admin/feedback")
public class AdminFeedbackController {

    @Autowired
    private AdminFeedbackService adminFeedbackService;

    @GetMapping("/list")
    @ApiOperation("获取反馈列表")
    public Result<List<AdminFeedbackVO>> getFeedbackList(){
        List<AdminFeedbackVO> list = adminFeedbackService.getFeedbackList();
        return Result.success(list);
    }
}
